﻿using System.ComponentModel.DataAnnotations;

namespace WH.Contracts.Systems.Config
{
    public class ConfigInputDto
    {
        /// <summary>
        ///  Key
        ///</summary>
        [Required]
        [MaxLength(50, ErrorMessage = "Key最大长度未50")]
        public string Key { get; set; } = null!;
        /// <summary>
        ///  值
        ///</summary>
        [Required]
        public string Value { get; set; } = null!;
        /// <summary>
        /// 描述 
        ///</summary>
        [Required]
        [MaxLength(255, ErrorMessage = "描述最大长度未255")]
        public string Description { get; set; } = null!;


        /// <summary>
        /// 排序 
        ///</summary>
        public int SortNo { get; set; }

        /// <summary>
        /// 类型 1：JSON 2：Array
        /// </summary>
        public int Type { get; set; }

        /// <summary>
        /// 父级id
        /// </summary>
        [Required]
        public string ParentId { get; set; } = null!;
    }
}
